package com.jxy.homepage.service.feign;

import com.jxy.BBM_info.BBM;
import com.jxy.homepage.service.feign.impl.MailClientImpl;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.scheduling.annotation.Async;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * MailClient
 *
 * @author Jxy
 * @date 2022/3/11
 * @Description mail 微服务
 */
@FeignClient(name = "mail", fallback = MailClientImpl.class, path ="api")
public interface MailClient {

    /**
     * mail调用简单发送邮件
     * @param bbm 统一
     */
    @PostMapping("/sendMail")
//    @Async()
    void sendMail(@RequestBody BBM bbm);
}
